package pack.characters;

import com.jme.bounding.BoundingBox;
import com.jme.math.Vector3f;
import com.jme.scene.Node;
import com.jme.scene.Spatial;
import com.jme.scene.shape.Box;
import com.jmex.physics.DynamicPhysicsNode;
import com.jmex.physics.PhysicsNode;
import com.jmex.physics.PhysicsSpace;
import com.jmex.physics.material.Material;

public class Player 
{
	private DynamicPhysicsNode player;
	private Box b;
	public Player(PhysicsSpace physicsSpace)
	{
		b = new Box("The player", new Vector3f(0,0,0), 100f, 200f, 100f);
		b.setModelBound(new BoundingBox());
		b.updateModelBound();
		
		player = physicsSpace.createDynamicNode();    	
		player.generatePhysicsGeometry();    	
    	final Material playerMaterial = new Material( "player material" );
        player.setMaterial( playerMaterial );
    	
	}
	
	public DynamicPhysicsNode getDynamicNode(){
		return player;
	}
	
    public PhysicsNode getNode() {
    	return (PhysicsNode)player;
    }
    
    public Spatial getSpatial(){
    	return b;
    }
}
